package chapter7.No7_7_线程异常处理的传递;

/**
 * 异常处理的传递 对象 > 线程组 > 默认
 * Created by Administrator on 2016/12/8.
 */
public class Main {
    public static void main(String[] args) {
        MyThreadGroup group = new MyThreadGroup("我的线程组");
        MyThread a = new MyThread(group, "A");
        a.setUncaughtExceptionHandler(new ObjectUncaughtExceptionHandler());
        Thread.setDefaultUncaughtExceptionHandler(new StaticUncaughtExceptionHandler());
        a.start();
    }
}
